import { IPSSysBIDimension } from './ipssys-bidimension';
import { IPSSysBIHierarchy } from './ipssys-bihierarchy';
import { PSModelObjectImpl } from '../psmodel-object-impl';

export class PSSysBIDimensionImpl extends PSModelObjectImpl implements IPSSysBIDimension {
  protected allpssysbihierarchies: IPSSysBIHierarchy[] | null = null;

  getAllPSSysBIHierarchies(): IPSSysBIHierarchy[] | null {
    if (this.allpssysbihierarchies == null) {
      this.allpssysbihierarchies = this.fillChildListModel(this.M.getAllPSSysBIHierarchies, 'bi.IPSSysBIHierarchy') as IPSSysBIHierarchy[];
    }
    return this.allpssysbihierarchies;
  }

  get allPSSysBIHierarchies(): IPSSysBIHierarchy[] | null {
    return this.getAllPSSysBIHierarchies();
  }

  findPSSysBIHierarchy(objKey: any): IPSSysBIHierarchy | null {
    return this.getPSModel5('bi.IPSSysBIHierarchy', this.getAllPSSysBIHierarchies(), objKey) as IPSSysBIHierarchy;
  }

  get codeName(): string {
    return this.M.codeName;
  }

  get dimensionTag(): string {
    return this.M.dimensionTag;
  }

  get dimensionTag2(): string {
    return this.M.dimensionTag2;
  }

  get dynaModelFilePath(): string {
    return this.M.dynaModelFilePath;
  }

  get memo(): string {
    return this.M.memo;
  }

  get name(): string {
    return this.M.name;
  }

  get userCat(): string {
    return this.M.userCat;
  }

  get userTag(): string {
    return this.M.userTag;
  }

  get userTag2(): string {
    return this.M.userTag2;
  }

  get userTag3(): string {
    return this.M.userTag3;
  }

  get userTag4(): string {
    return this.M.userTag4;
  }

  get cls(): string {
    return 'PSSysBIDimensionImpl';
  }

  instanceof(cls: string): boolean {
    if (cls == 'bi.IPSBIDimension' || cls == 'bi.IPSSysBIDimension') return true;
    return super.instanceof(cls);
  }
}
